Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

class System.​Linq.​Lookup<​TKey, TElement>

Assembly: System.Linq

Inheritance: object → Lookup

Implemented Interfaces

Represents a collection of keys each mapped to one or more values.

Properties

public int
Count
Gets the number of key/value collection pairs in the <see cref="T:System.Linq.Lookup`2" /> .
Item

Methods

ApplyResultSelector​(Func<​TKey, Collections.​Generic.​IEnumerable<​TElement>, TResult> resultSelector)
Applies a transform function to each key and its associated values and returns the results.
Returns A collection that contains one value for each key/value collection pair in the <see cref="T:System.Linq.Lookup`2" /> .
resultSelector A function to project a result value from each key and its associated values.
public bool
Contains​(TKey key)
Determines whether a specified key is in the <see cref="T:System.Linq.Lookup`2" /> .
Returns <see langword="true" /> if <paramref name="key" /> is in the <see cref="T:System.Linq.Lookup`2" /> ; otherwise, <see langword="false" /> .
key The key to find in the <see cref="T:System.Linq.Lookup`2" /> .
public Collections.​Generic.​IEnumerator<​IGrouping<​TKey, TElement>>
GetEnumerator​()
Returns a generic enumerator that iterates through the <see cref="T:System.Linq.Lookup`2" /> .
Returns An enumerator for the <see cref="T:System.Linq.Lookup`2" /> .
public bool
Equals​(object obj)
Inherited from object
protected void
Finalize​()
Inherited from object
public int
GetHashCode​()
Inherited from object
public Type
GetType​()
Inherited from object
protected object
MemberwiseClone​()
Inherited from object
public string
ToString​()
Inherited from object